package com.example.springbootapplication;

import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.context.ConfigurableApplicationContext;

/**
 * spring 应用上下文引导类
 * @Author acy
 * @Date 2019/04/27
 */
@SpringBootApplication
public class SpringApplicationContextBootstrap {
	public static void main(String[] args) {
		ConfigurableApplicationContext context = new SpringApplicationBuilder(SpringApplicationContextBootstrap.class).run(args);
		System.out.println("ConfigurableApplicationContext 类型---"+context.getClass().getName());
		System.out.println("Environment 类型---"+context.getEnvironment().getClass().getName());
		context.close();
	}
}
